#ifndef _E_SCREEN_H_
#define _E_SCREEN_H_

#include "ESceneObject.h"
#include "EEntityManager.h"
#include "EResource.h"
#include "ECamera.h"
#include "EDesc.h"
#include "eH.h"

namespace engine {

//------------------------------------------------------------
class EScreenDesc : public EDesc
{
public:
  string      m_sBagroundFileName;

  bool  isValid() const { return true; }
};

//------------------------------------------------------------
class EScreen : public EResource, public ESceneObject
{
  friend class EScene;

  MaterialPtr     m_Material;
  SceneNode*      m_pNode;
  Rectangle2D     m_Rect;
  ECamera         m_Camera;

  void  initRect     ();

protected:
  EScreen(const string& sName, const EScreenDesc& desc);
  virtual ~EScreen();
public:

  virtual bool      load              ( );
  virtual bool      update            ( const EGameTime& time );
  virtual bool      startGame         ( );
  virtual bool      updateGame        ( const EGameTime& time );
  virtual bool      endGame           ( );
};

} // end namespace

#endif